<!DOCTYPE html>
<@compress single_line=isCompress>
<html lang="en">
<head>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>${platform} - <#if (art.id)?? >编辑<#else>发布</#if>文章-${typeName}</title>
    <#include "/pager/common/quote.ftl" />
    <link rel="stylesheet" href="${root}/assets/common/kindeditor/themes/default/default.css" />
	<link rel="stylesheet" href="${root}/assets/common/kindeditor/plugins/code/prettify.css" />
	<script charset="utf-8" src="${root}/assets/common/kindeditor/kindeditor-all-min.js"></script>
	<script charset="utf-8" src="${root}/assets/common/kindeditor/lang/zh-CN.js"></script>
	
	<script type="text/javascript" src="${root}/assets/common/vendors/jquery-file-upload/js/vendor/jquery.ui.widget.js"></script>
	<script type="text/javascript" src="${root}/assets/common/vendors/jquery-file-upload/js/jquery.fileupload.js"></script>
	<script type="text/javascript" src="${root}/assets/common/vendors/jquery-file-upload/js/jquery.iframe-transport.js"></script>
	<script type="text/javascript" src="${root}/assets/common/vendors/jquery-file-upload/js/jquery.fileupload-process.js"></script>
	<script type="text/javascript" src="${root}/assets/common/vendors/jquery-file-upload/js/jquery.fileupload-validate.js"></script>
	<script type="text/javascript" src="${root}/assets/biz-logic/js/common/file.upload.js"></script>
	<link rel="stylesheet" href="${root}/assets/biz-logic/css/common/common.css"/>
<script type="text/javascript">
	var global = {
		type : "${type}",
		recommend : "${(art.recommend)!''}",
		spaceShow : "${(art.spaceShow)!''}",
		sysFid : "${(art.file)!}"
	};
	$(function(){
		$("#recommend").val(global.recommend);
		$("#spaceShow").val(global.spaceShow);
	});
</script>
</head>
<body>
    <#include "/pager/biz-logic/include/top.ftl" />
<div id="page-wrapper"><!--END PAGE HEADER & BREADCRUMB--><!--BEGIN CONTENT-->
<div class="page-content">
    <div id="tab-general">
        <div class="row">
            <div class="col-lg-12">
                <div class="portlet">
                    <div class="portlet-header">
                        <div class="caption"><#if (art.id)?? >编辑<#else>发布</#if>文章-${typeName}</div>
                    </div>
                    <div class="portlet-body">
                        <div class="table-tools">
                            <div class="row">
                                <div class="col-lg-12">
                                    <form id="submitForm" class="form-horizontal article" method="post" onsubmit="return false;" action="${base}/art/submit_edit_${type}.html">
                                   		<div class="form-group">
                                   		<input type="hidden" name="id" value="${(art.id)!''}"/>
                                            <label for="nick" class="col-sm-1 control-label">是否推荐：</label>
                                            <div class="col-sm-3">
                                                <select class="form-control" name="recommend" id="recommend">
                                                	<option value="0">不推荐</option>
                                                	<option value="1">推 荐</option>
                                                </select>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label for="nick" class="col-sm-1 control-label">前端显示：</label>
                                            <div class="col-sm-3">
                                                <select class="form-control" name="spaceShow" id="spaceShow">
                                                	<option value="0">不显示</option>
                                                	<option value="1">显 示</option>
                                                </select>
                                            </div>
                                        </div>
                                        <#if type=='special'>
                                        	<div class="form-group">
	                                            <label for="nick" class="col-sm-1 control-label">专家名：<span style="color: #ff0000">*</span></label>
	                                            <div class="col-sm-3 custom">
	                                                <input type="text" class="form-control" name="expert" id="expert"
	                                                       value="${(art.expert)!''}" maxlength="10" required="required"/>
	                                            </div>
	                                        </div>
	                                        <div class="form-group">
	                                            <label for="nick" class="col-sm-1 control-label">职 称：<span style="color: #ff0000">*</span></label>
	                                            <div class="col-sm-3 custom">
	                                                <input type="text" class="form-control" name="position" id="position"
	                                                       value="${(art.position)!''}" maxlength="30" required="required"/>
	                                            </div>
	                                        </div>
                                        </#if>
                                        <div class="form-group">
			                                <label class="col-md-1 control-label">封面图片：</label>
			                                <div class="col-sm-3">
	                                        	<button class="btn btn-primary fileinput-button col-sm-3">
		                                        	<i class="fa fa-cloud-upload"></i> <span>上传文件</span>
	                                        		<input type="file" name="uploadFile" id="uploadFile_pic"
	                                                       data-url="${base + '/document/upload-article_imgs.do?fileModule=${type}'}" />
		                                        </button>
			                                    <span class="text-red"></span>
		                                        <span class="hidden-input">
		                                        	<input type="hidden" name="file" value="${art.file!''}" class="input-file-id">
		                                        </span>
			                                </div>
			                            </div>
			                            <div class="form-group" style="display:<#if art.file??><#else>none</#if>" id="uploadFile_pic_box">
			                                <label class="col-md-1 control-label"></label>
			                                <div class="col-sm-10 sucess-deal" style="display:<#if art.file??><#else>none</#if>">
			                                    <a href="${root}/admin/document/file-${(art.file)!}.do" target="_blank" data-toggle="tooltip" data-placement="top" title="查看高清图片">
				                                    <img class="image" width="400px" src="${root}/admin/document/file-${(art.file)!}.do" />
			                                    </a>
			                                    <p class="name"></p>
			                                </div>
			                                <div class="col-sm-10 progress-info" style="display:none">
			                                    <div class="progress progress-striped active" role="progressbar" aria-valuemin="0"
			                                         aria-valuemax="100" aria-valuenow="0">
			                                        <div class="progress-bar progress-bar-success" style="width:0%;">
			                                        	<span class="progress-completed state" >0%</span>
			                                        </div>
			                                    </div>
			                                </div>
			                            </div>
                                        <div class="form-group">
                                            <label for="nick" class="col-sm-1 control-label">标 题：<span style="color: #ff0000">*</span></label>
                                            <div class="col-sm-10">
                                                <input type="text" class="form-control" name="title" id="title"
                                                       value="${(art.title)!''}" maxlength="50"/>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label for="nick" class="col-sm-1 control-label">摘 要：</label>
                                            <div class="col-sm-10">
                                                <textarea style="height:100px" class="form-control" name="summary" maxlength="1000">${(art.summary)!''}</textarea>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label for="phone" class="col-sm-1 control-label">内 容：<span style="color: #ff0000">*</span></label>
                                            <div class="col-sm-10">
                                                <textarea name="content" id="content" class="form-control" style="visibility:hidden;height:510px">${(art.content)!''}</textarea>
                                            </div>
                                            <div class="col-sm-1 error-msg"><span class="msg-box n-right" for="content"></span></div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-1 control-label"></label>
                                            <div class="col-sm-6">
                                            	<input type="button" class="btn btn-warning" id="close_btn" value="关 闭"/>
                                                <input type="submit" class="btn btn-primary" id="submit_btn" value="确认保存"/>
                                            </div>
                                        </div>
                                    </form>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
    <#include "/pager/biz-logic/include/bot.ftl" />
</@compress>
